|
|
|
|
|
|
|
with real-world entities in the client's environment. The Data Services package houses the classes that facilitate the saving of precious business information from an application session to a persistent information repository, such as a database or a flat file. The BankAccounts collection class is a business domain class, so it belongs in the Business Services package. Drag it to the Business Services package folder now. Click the Next button. The wizard will now copy the collection class to your current model. Click the Finish button. Click the Close button. That's it. |
|
|
|
|
|
|
|
|
Now let's generate the code. Choose Tools | Code Generation Wizard from the menu in Visual Modeler. The Code Generation Wizard dialog will appear. Click the Next button. In the current step, you're asked to select the classes in the model for which you want to generate code. Because by default all the classes are chosen for you, simply click the Next button. You are now asked to set the code generation properties of each class member (property or method). To keep things simple, just click the Next button. The current step asks you to set general code generation options, such as whether to include debug code, Err.Raise, and comments in code, as well as whether you want to generate new collection classes. By default, all these options are selected. Let's keep them. Click the Next button. The wizard now displays a list of your classes. Click the Finish button. The wizard generates the code for you. When it's finished, you'll see a summary of actions the wizard did during the process. When you're satisfied with what you see, click the Close button. |
|
|
|
|
|
|
|
|
By now, you might be wondering where your newly generated code went. Don't worry. Switch to your current Visual Basic session. (If you didn't have Visual Basic running during the code generation process, Visual Modeler would have notified you that Visual Basic must be running in order to generate code.) You will see several cascaded code windows for each class created. |
|
|
|
|
|
|
|
|
Putting the Finishing Touches on the Application |
|
|
|
|
|
|
|
|
Although Visual Modeler is a smart tool, it's not smart enough to provide all the logic necessary to make your code work the way your client wants the system to work. If it were, you would probably be out of a job! |
|
|
|
|
|
|
|
|
For your newly generated code to work, you'll have to re-examine the use cases to further determine what the user wants. This activity might prompt several more use-case iterations with the users to ensure that every requirement for the current release of the system is in place and that there are no discrepancies. It's far less costly in time and money to verify use cases before coding than afterwards, so be patient with this process. |
|
|
|
|
|